package com.ruoyi.project.museum.api;

import com.ruoyi.common.utils.poi.ExcelUtil;
import com.ruoyi.framework.aspectj.lang.annotation.Log;
import com.ruoyi.framework.aspectj.lang.enums.BusinessType;
import com.ruoyi.framework.web.controller.BaseController;
import com.ruoyi.framework.web.domain.AjaxResult;
import com.ruoyi.framework.web.page.TableDataInfo;
import com.ruoyi.project.museum.type.domain.ExhibitType;
import com.ruoyi.project.museum.type.service.IExhibitTypeService;
import org.apache.shiro.authz.annotation.RequiresPermissions;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.ui.ModelMap;
import org.springframework.web.bind.annotation.*;

import java.util.List;

/**
 * 文物类型Api
 * 
 * @author summer
 * @date 2021-03-15
 */
@Controller
@RequestMapping("/api/museum/type")
public class ExhibitTypeApi extends BaseController
{

    @Autowired
    private IExhibitTypeService exhibitTypeService;

    /**
     * 查询文物类型列表
     */
    @PostMapping("/list")
    @ResponseBody
    public TableDataInfo list(ExhibitType exhibitType)
    {
        startPage();
        List<ExhibitType> list = exhibitTypeService.selectExhibitTypeList(exhibitType);
        return getDataTable(list);
    }
}
